<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@page import="com.solution.common.config.PublicConfig"%>
<%@page import="com.solution.admin.order.constants.OrderConstants"%>
<%@page import="com.solution.admin.home.constants.IndexConstants"%>
<%
	String basePath = PublicConfig.ROOT_PATH;
	String imgRootURL = PublicConfig.IMG_ROOT_URL;
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>支付</title>
<meta name="keywords" content="" />
<meta name="description" content="" />
<meta content="zh-cn" http-equiv="content-language" />
<meta content="" name="copyright" />
<link rel="stylesheet" type="text/css" href="<%=basePath%>/statics/css/style.css?t=1" />
<link rel="stylesheet" type="text/css" href="<%=basePath%>/statics/css/public.css" />
<!-- 大图查看插件 -->
<link rel="stylesheet" type="text/css" href="<%=basePath%>/statics/plugins/fancybox/css/fancybox.css" />
<!--[if lte IE 6]> 
<script type="text/javascript" src="js/PNG.js"></script> 
<script> 
PNG.fix('*'); 
</script> 
<![endif]-->
<script type="text/javascript">
	//系统域名 
	var rootPath = '<%=basePath%>';
	// 系统上传文件展示域名
	var imgRootURL = '<%=imgRootURL%>';
</script>
<style>
	.pic2{position:relative;width:48px;height:48px;margin:auto;display:inline-block;margin-right:10px;margin-bottom:10px;}
	.pic2 img{width:48px;height:48px;border:1px solid #ccc;}
	.pic2 input{position:absolute;left:0;top:0;width:100%;height:100%;opacity:0;cursor:pointer;}
	.pic2 a.icon_close{position:absolute;display:block;right:-8px;top:-8px;width:18px;height:18px;background:url(<%=basePath%>/statics/images/icon_close2.png) no-repeat;}
	.bank_list1_con dl dt{float:left;margin-right:60px;margin-bottom:10px;width:258px;min-height:130px;border:1px solid #ccc;}
    .upload_tips{display:inline-block;width:100%;margin-bottom:10px;margin-top:-5px;}
	.upload_tips p{margin-left:22px;font-size:14px;color:#999}
	.upload_tips p u{display:inline-block;width:16px;height:16px;background:url(<%=basePath%>/statics/images/icon_notice.png) no-repeat;vertical-align:middle;margin-right:5px;}
	.upload_tips p span{display:inline-block;vertical-align:middle}
</style>
</head>
<body style="background:#fff">
	<c:set var="rootPath" value="<%=basePath %>"></c:set>
	<c:set var="imgRootURL" value="<%=imgRootURL %>"></c:set>
	<div class="wrap">

		<!---头部公共部分开始-->
		<div class="header">
			<jsp:include page="../header_top.jsp" />
		</div>
		<div class="member_header">
			<div class="member_header_con">
				<h1>
					<a href="${rootPath}/pc/index"><img src="${rootPath}/statics/images/logo5.png" /></a>
				</h1>
				<div class="member_nav">
					<ul>
						<li><a class="a1" href="${rootPath}/pc/index">首页</a></li>
						<li onmouseover="this.className='hover'"
							onMouseOut="this.className=''"><a href="#" class="a1">账户管理<i></i></a>
							<dl>
								<dd>
									<p>
										<span>账户管理</span><i></i>
									</p>
								</dd>
								<dt>
									<a href="<%=basePath%>/pc/my"><p>我的信息</p></a>
								</dt>
								<dt>
									<a href="<%=basePath%>/pc/my/mypwd"><p>修改密码</p></a>
								</dt>
								<dt>
									<a href="<%=basePath%>/pc/my/address"><p>收货地址</p></a>
								</dt>
							</dl></li>
					</ul>
				</div>
				<div class="member_header_right">
					<div class="search_part11">
						<form action="<%=basePath%>/pc/product/search">
							<input type="text" name="searchKey"  class="inputstyle11" /> <input type="submit"
								class="inputbtn11" value="搜索" />
						</form>
					</div>
					<div class="cart_part1">
						<p>
							<a href="${rootPath}/pc/shoppingcart/list"><i></i><span>我的购物车</span><em id="shopCount">0</em></a>
						</p>
					</div>
				</div>
			</div>
		</div>
	</div>
	<!---头部公共部分结束-->
	
	
	<div class="site_wrap115">
		<div class="site_wrap115_con">
			<div class="order_info11">
				<div class="order_info11_1">
					<input type="hidden" id="order_code"  value="${orderCode}"/>
					<h1>订单提交成功，请尽快付款！订单号：${orderCode}</h1>
					<p>请您在24小时内完成支付，否则订单会被自动取消</p>
					<h3>
						应付金额 <b>${realPayMoney }</b> 元
					</h3>
				</div>
				<div class="order_info11_2">
					<p>收货地址：${deliveryAddress}  收货人：${receiverName} ${receiverMobile }</p>
				</div >
				<div class="order_info11_2">
					<a id="print_contract" href="javascript:void(0);" style="font-size:16px;color:#666;line-height:24px;color:#dd2726;font-weight: blod;" >单击下载合同</a>
				</div>
			</div>

			<div class="order_info12">
				<div class="hd">
					<h3>
						<span>线下支付</span><i></i>
					</h3>
				</div>
				<div class="bd">
					<div class="zf_way zf_way1">
						<ul>
							<li style="border-bottom: 1px solid #ccc">
								<div class="mylabel" payType="<%=OrderConstants.ORDER_PAY_TYPE.PUBLIC_BANK_PAY.getCode() %>">
									<div class="xx_1">
										<i></i>
										<div class="txt1">
											<span>对公转账</span>
											<h4>支付 <s>${realPayMoney }</s>元</h4>
										</div>
									</div>
									<div class="bank_list1">
										<div class="bank_list11">
											<div class="bank_list1_con">
												<dl>
													<c:forEach items="${payAccountList }" var="payAccount" varStatus="status" >
														<c:if test="${payAccount.payType eq '03'}">
															<dt style="width:300px;">
																<div class="box16">
																	<input type="hidden" name="accountId" value="${payAccount.id }"/>
																	账户名称：${payAccount.accountName }<br />
																	银行账户：${payAccount.bankAccount }<br />
																	银行名称：${payAccount.bankName }<br />
																	所在支行：${payAccount.bankChild }
																</div>
															</dt>
														</c:if>
													</c:forEach>
												</dl>	
											</div>
										</div>
									</div>
									<div class="xx_1">
										<div class="txt1" style="margin-left:0">
											<dl>
												<dt style="margin-left:22px">
													<b>上传支付凭证</b>
													<div class="txt2" id="publicImgDiv">
														<div class="input_part1">
															<input id="publicUpload" class="inputfile" tag="public" type="file" accept="image/png,image/jpeg" name="upload" onchange="ajaxFileUpload(this)"/>
															<input type="button" class="inputbtn1" value="点击上传" onclick="publicUploadButton(this);"/>
														</div>
													</div>
												</dt>
											</dl>
										</div>
									</div>
									<div class="upload_tips">
										<p><u></u><span>仅限上传图片，上传图片大小为5M以下</span></p>
									</div>
								</div>
						  	</li>
						</ul>
					</div>
					
					<div class="zf_way zf_way2">
						<ul>
							<li>
								<div class="mylabel" id="private_label" payType="<%=OrderConstants.ORDER_PAY_TYPE.PRIVATE_BANK_PAY.getCode() %>">
									<div class="xx_1">
										<i></i>
										<div class="txt1">
											<span>私人银行卡</span>
											<h4>支付 <s>${realPayMoney }</s>元</h4>
										</div>
									</div>
									<div class="bank_list1">
										<div class="bank_list12">
											<div class="bank_list1_con">
												<dl>
													<c:forEach items="${payAccountList }" var="payAccount" varStatus="status" >
														<c:if test="${payAccount.payType eq '04'}">
															<dt>
																<div class="box16">
																	<input type="hidden" name="accountId" value="${payAccount.id }"/>
																	账户姓名：${payAccount.accountName }<br />
																	银行账户：${payAccount.bankAccount }<br />
																	银行名称：${payAccount.bankName }<br />
																	所在支行：${payAccount.bankChild }
																</div>
															</dt>
														</c:if>
													</c:forEach>
												</dl>
											</div>
										</div>
									</div>
									<div class="xx_1">
										<div class="txt1" style="margin-left:0">
											<dl>
												<dt style="margin-left:22px">
													<b>上传支付凭证</b>
													<div class="txt2" id="privateImgDiv">
														<div class="input_part1">
															<input id="privateUpload" class="inputfile" tag="private" type="file" accept="image/png,image/jpeg" name="upload" onchange="ajaxFileUpload(this)"/>
															<input type="button" class="inputbtn1" value="点击上传" onclick="privateUploadButton(event);"/>
														</div>
													</div>
												</dt>
											</dl>
										</div>
									</div>
									<div class="upload_tips">
										<p><u></u><span>仅限上传图片，上传图片大小为5M以下</span></p>
									</div>
								</div>
							</li>
						</ul>
					</div>
				</div>

			</div>
			<div class="order_info12">
				<div class="hd">
					<h3>
						<span>线上支付</span><i></i>
					</h3>
				</div>
				<div class="bd">
					<div class="zf_way zf_way3">
						<ul>
							<li>
								<input class="input_radio" type="radio" />
								<div class="mylabel" id="ali_QR_pay" payType="<%=OrderConstants.ORDER_PAY_TYPE.ALIPAY.getCode() %>" >
									<div class="xx_1">
										<i></i>
										<div class="txt1">
											<em><img src="${rootPath}/statics/images/icon_alipay.png" /></em><span>支付宝</span>
										</div>
									</div>
									<div class="bank_list1" style="text-align:center;padding:10px;line-height: 30px;">
										<input type="hidden" id="get_swiftpass_alipay_code" value="false"/>
										<span><b>请使用支付宝扫码支付</b></span>
										<div align="center">
											<img id="swiftpass_alipay_code" src="" style="width:250px;height:250px;"/>
											<br/><span style="color:red;font-size:14px;font-weight:bold;">支付成功后，请稍等片刻....，系统将会自动跳转支付成功页面。</span>
										</div>
									</div>
								</div>
							</li>
							<li>
								<input class="input_radio" type="radio" />
								<div class="mylabel" id="wx_QR_pay" payType="<%=OrderConstants.ORDER_PAY_TYPE.WXPAY.getCode() %>" >
									<div class="xx_1">
										<i></i>
										<div class="txt1">
											<em><img src="${rootPath}/statics/images/icon_weixin.png" /></em><span>微信</span>
										</div>
									</div>
									<div class="bank_list1" style="text-align:center;padding:10px;line-height: 30px;">
										<input type="hidden" id="get_QR_code" value="false"/>
										<span><b>请使用微信扫码支付</b></span>
										<div align="center">
											<img id="swiftpass_wxpay_code" src="" style="width:250px;height:250px;"/>
											<br/><span style="color:red;font-size:14px;font-weight:bold;">支付成功后，请稍等片刻....，系统将会自动跳转支付成功页面。</span>
										</div>
										<%-- 
										<br/>
										<div id="qrcode" align="center"></div>
										<br/>
										--%>
									</div>
								</div>
							</li>
						</ul>
					</div>
				</div>
			</div>
			<div class="order_info12" style="padding-bottom: 0" id="payDiv">
				<div class="pay_info3">
					<p>&nbsp;</p>
					<strong><a id="btn_pay" href="javascript:void(0);" class="btn2">立即支付</a></strong>
				</div>
			</div>
		</div>
	</div>
	<!---网站底部开始-->
	<jsp:include page="../footer.jsp?showQaFlag=0" />
	<!---网站底部结束-->
	</div>

<script charset="utf-8" language="javascript" type="text/javascript" src="<%=basePath%>/statics/js/jquery.1.11.3.min.js"></script>
<script type="text/javascript" src="<%=basePath%>/statics/js/jquery.form.js"></script>
<script type="text/javascript" src="<%=basePath%>/statics/js/jquery.validate.js"></script>
<script type="text/javascript" src="<%=basePath%>/statics/js/jquery.qrcode.min.js"></script>
<script type="text/javascript" src="<%=basePath%>/statics/plugins/upload/ajaxfileupload.js"></script>
<script type="text/javascript" src="<%=basePath%>/statics/plugins/layer/layer.js"></script>
<!-- 大图查看插件 -->
<script type="text/javascript" src="<%=basePath%>/statics/plugins/fancybox/js/jquery.fancybox-1.3.1.pack.js"></script>
<script type="text/javascript" src="<%=basePath%>/js/order/order_pay.js?v=20180206"></script>
<script type="text/javascript">
$(function() {
		/**
		 * 获取购物车数量
		 */
		$.ajax({
			type: 'POST',
			url: rootPath + "/pc/shoppingcart/getShoppingcarCount",
			async: true,
			dataType: 'json',
			success: function(json) {
				if(json.code == '1') {
					$("#shopCount").html(json.data);
				}
			}
		});
		
		
		$("#print_contract").click(function(){
			var url = rootPath + "/pc/order/toPrintOrderContract?orderCode="+$("#order_code").val();
		    layer.open({
		    	  type: 2,
		    	  title: '订单合同',
		    	  shadeClose: true,
		    	  shade: 0.8,
		    	  area: ['780px', '90%'],
		    	  content: url
		    }); 
		});
		
		
	});
	</script>
</body>
</html>